package com.qzboot.basic.service.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.qzboot.facade.entity.SysMenu;

import java.util.List;

/**
 * @author zengzhihong
 */
public interface SysMenuMapper extends BaseMapper<SysMenu> {

    /**
     * 获取用户权限
     *
     * @param userId
     * @return
     */
    List<String> listPermsByUserId(Long userId);

    /**
     * 通过userId查询
     *
     * @param userId
     * @return
     */
    List<SysMenu> listByUserId(Long userId);


    /**
     * 通过角色ID查询菜单ID
     *
     * @param roleId
     * @return
     */
    List<Long> listMenuIdByRoleId(Long roleId);
}
